﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace mvcDemo.Controllers
{
    public class JsonMessage
    {
        public string error;
        public string syserror;
        public string StackTrace;
        public object data;

        public JsonMessage()
        {
            LogTool.Info("NORMAL","");
        }

        public JsonMessage(string err, string syserr)
        {            
            error = err;
            syserror = syserr;
            LogTool.Debug("ERROR", new string[] { error });
        }

        public JsonMessage(string err,string syserr,string st)
        {
            error = err;
            syserror = syserr;
            StackTrace = st;
            LogTool.Error("SYSERROR", new string[] { syserr, st });
        }

        public JsonMessage(object d)
        {
            data = d;
            LogTool.Info("NORMAL", "");
        }
    }
}